/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package bean_session;

import entity_bean.Personne;
import entity_bean.PersonneFacade;
import java.sql.Date;
import javax.ejb.EJB;
import javax.ejb.Stateless;

/**
 *
 * @author Mamoune
 */
@Stateless
public class Admin implements AdminLocal {
    @EJB
    private PersonneFacade personneFacade;

    // Add business logic below. (Right-click in editor and choose
    // "Insert Code > Add Business Method")

    @Override
    public void addPersonne(int id, String nom, String prenom, String pass, String email, String bureau, Date naissance, Date date_arrivee) {
          Personne personne = new Personne();
          personne.setId(id);
          personne.setNom(nom);
          personne.setPrenom(prenom);
          personne.setPass(pass);
          personne.setBureau(bureau);
          personne.setNaissance(naissance);
          personne.setDateArrivee(date_arrivee);
         
          personneFacade.create(personne);
    }

    
    }

    
    
    
    

